import request from '@/utils/request'

// base
const base = process.env.VUE_APP_BASE_API6 + '/mapping/brand'

export function queryWMBrandList(params) {
  return request({
    url: base + '/queryWMBrandList',
    method: 'get',
    params
  })
}

export function batchSave(val) {
  return request({
    url: base + '/batchSave',
    method: 'post',
    data: val
  })
}

export function queryChannelBrandList(params) {
  return request({
    url: base + '/queryChannelBrandList',
    method: 'post',
    data: params
  })
}

export function batchDelete(val) {
  return request({
    url: base + '/batchDelete',
    method: 'post',
    data: val
  })
}

export function relieveBind(val) {
  return request({
    url: base + '/relieveBind',
    method: 'post',
    data: val
  })
}

export function lazyLoadWmBrandMapping(val) {
  return request({
    url: base + '/lazyLoadWmBrandMapping',
    method: 'post',
    data: val
  })
}

export function syncChannleData(channelId) {
  return request({
    url: base + '/syncChannleData?channelId=' + channelId,
    method: 'get'
  })
}

export function batchAddWMDJBrand(val) {
  return request({
    url: base + '/batchAddWMDJBrand',
    method: 'post',
    data: val
  })
}
